<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<script type="text/javascript">
			window.onload = function(){
				var num1 = document.getElementsByTagName("input");
				console.log(num1[1]);
			}
		</script>
	</head>
	<body>
		<div>
			<input type="text" value="1"><br />
			<input type="text" value="2">
		</div>
	</body>
</html>
